package com.user.entity;

import java.util.Objects;

public class School {
    int schoolid;
    String schoolname;

    public School(int schoolid, String schoolname) {
        this.schoolid = schoolid;
        this.schoolname = schoolname;
    }

    public School() {
    }

    public int getSchoolid() {
        return schoolid;
    }

    public void setSchoolid(int schoolid) {
        this.schoolid = schoolid;
    }

    public String getSchoolname() {
        return schoolname;
    }

    public void setSchoolname(String schoolname) {
        this.schoolname = schoolname;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        School school = (School) o;
        return schoolid == school.schoolid && Objects.equals(schoolname, school.schoolname);
    }

    @Override
    public int hashCode() {
        return Objects.hash(schoolid, schoolname);
    }

    @Override
    public String toString() {
        return "School{" +
                "schoolid=" + schoolid +
                ", schoolname='" + schoolname + '\'' +
                '}';
    }
}
